package cn.iune.erp.payment;

import java.math.BigDecimal;
import java.sql.Date;
import java.text.ParseException;
import java.util.List;
import com.alibaba.fastjson.JSONObject;

import cn.iune.common.base.IBizDataIface;


public interface IAccountPaymentService extends IBizDataIface {

	public void insert(AccountPayment a);
	
	public void update(AccountPayment a);

	public void delete(String fID);

	JSONObject save(JSONObject object) throws ParseException ;

	AccountPayment getByID(String fID);

	int confirm(String fID);

	int active(String fID);

	int open(String fID);

	int close(String fID);

	int unAgree(String fID);

	int confirm(AccountPayment a);

	int active(AccountPayment a);

	int open(AccountPayment a);

	int close(AccountPayment a);

	int unAgree(AccountPayment a);


	int agreeIt(String fID, String tUsercode, String tUsername, String userId);

	int agreeIt(AccountPayment a, String tUsercode, String tUsername, String userId);

//	AccountPayment getYSKDByOriginNo(String originNo, String enterpriseNo);

	int updateYSKDClearedAmount(String accountPaymentNo, String enterpriseNo, BigDecimal clearAmount);

	int updateYFKDClearedAmount(String accountPaymentNo, String enterpriseNo, BigDecimal clearAmount);

	int updateSettleCode(String fID, String invoiceCode);

	int updateSettleCategory(AccountPayment accountPayment, String settleCategory, String settleCategoryLabel,
			String capitalID, String capitalNo, String capitalName, String capitalFullName);

	BigDecimal getRecAmountToday(List<Object> params);

	BigDecimal getPayAmountToday(List<Object> params);

	JSONObject saveDetail(JSONObject object) throws ParseException;

	JSONObject newDataDetail(JSONObject param);

	JSONObject queryDataDetail(JSONObject param);


	JSONObject querySimple(JSONObject data) ;



	AccountPayment packing(String billType, String billTypeName, String systemCode, int flowType, String revOpay,
			int direction, String autoCode, String origin, String originName, String billNo, String cUsercode,
			String cUsername, String userId, String employeeNo, String employeeName, String enterpriseNo,
			String enterpriseName);


	AccountPayment accountPaymentYFKDInsert(String origin, String originName, String originNo, String dealObject,
			String dealObjectLabel, String customerID, String customerNo, String shortName, String customerName,
			String remark, BigDecimal orderAmount, String settleCategory, String settleCategoryLabel, String tradeNo,
			String orderNo, String autoState, int flowType, int cashSettle, String cUsercode, String cUsername,
			String userId, String employeeNo, String employeeName, String enterpriseNo, String enterpriseName);

//	AccountPayment getYSKDByNo(String accountPaymentNo, String enterpriseNo);

//	AccountPayment getYFKDByNo(String accountPaymentNo, String enterpriseNo);

//	AccountPayment getSKDJByNo(String accountPaymentNo, String enterpriseNo);

	AccountPayment packing(String cUsercode, String cUsername, String userId, String employeeNo, String employeeName,
			String enterpriseNo, String enterpriseName);

	List<AccountPayment> getUnclearYSKDList(String customerID, String enterpriseNo);

//	BigDecimal getUnclearYSKDAmount(String customerID, String enterpriseNo);


	int updateOrigin(String fID, String origin, String originName, String originNo);

	AccountPayment accountPaymentRDJQInsert(String origin, String originName, String originNo, String dealObject,
			String dealObjectLabel, String customerID, String customerNo, String shortName, String customerName,
			String remark, BigDecimal orderAmount, String tradeNo, String orderNo, String autoState, int flowType,
			int cashSettle, String cUsercode, String cUsername, String userId, String employeeNo, String employeeName,
			String enterpriseNo, String enterpriseName);

	int updateRDJQClearedAmount(String accountPaymentNo, String enterpriseNo, BigDecimal clearAmount);

//	AccountPayment getRDJQByNo(String accountPaymentNo, String enterpriseNo);

	List<AccountPayment> getUnclearYECZList(String customerID, String enterpriseNo);

	AccountPayment accountPaymentYSKDInsert(String guestNumber, String origin, String originName, String originNo,
			String dealObject, String dealObjectLabel, String customerID, String customerNo, String shortName,
			String customerName, String remark, BigDecimal orderAmount, String settleCategory,
			String settleCategoryLabel, String tradeNo, String orderNo, int flowType, int cashSettle, String cUsercode,
			String cUsername, String userId, String employeeNo, String employeeName, String enterpriseNo,
			String enterpriseName);

	AccountPayment accountPaymentYECZInsert(String origin, String originName, String originNo, String dealObject,
			String dealObjectLabel, String customerID, String customerNo, String shortName, String customerName,
			String remark, BigDecimal orderAmount, String settleCategory, String settleCategoryLabel, String tradeNo,
			String orderNo, int flowType, int cashSettle, String cUsercode, String cUsername, String userId,
			String employeeNo, String employeeName, String enterpriseNo, String enterpriseName);

	List<AccountPayment> getActualSKD(Date dateStart, Date dateEnd, String enterpriseNo);

	List<AccountPayment> getActualFKD(Date dateStart, Date dateEnd, String enterpriseNo);

	List<AccountPayment> getActualSKD(String customerID, Date dateStart, Date dateEnd, String enterpriseNo);

	List<AccountPayment> getActualFKD(String customerID, Date dateStart, Date dateEnd, String enterpriseNo);




}